import { createSlice } from "@reduxjs/toolkit";

const initialState = {
  theme: "light",
  language: "en",
};

const mainStore = createSlice({
  name: "main",
  initialState,
  reducers: {
    setTheme(state, action) {
      state.theme = action.payload;
    },
    setLanguage(state, action) {
      state.language = action.payload;
    },
  },
});

export default mainStore;
